Early Preview

This is currently very much a preview. Please feel free to try things out, but don't be upset if anything is not yet working. Feedback is welcome over on our GitHub Dicussions page.

interface System.​Threading.​Tasks.​Sources.​IValueTaskSource<​TResult>

Assembly: System.Runtime

Represents an object that can be wrapped by a <see cref="T:System.Threading.Tasks.ValueTask`1" /> .

Methods

TResult
GetResult​(short token)
Gets the result of the <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource`1" /> .
Returns The result of the <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource`1" /> .
token An opaque value that was provided to the <see cref="T:System.Threading.Tasks.ValueTask" /> constructor.
GetStatus​(short token)
Gets the status of the current operation.
Returns A value that indicates the status of the current operation.
token Opaque value that was provided to the <see cref="T:System.Threading.Tasks.ValueTask" /> 's constructor.
void
OnCompleted​(Action<​object> continuation, object state, short token, ValueTaskSourceOnCompletedFlags flags)
Schedules the continuation action for this <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource`1" /> .
continuation The continuation to invoke when the operation has completed.
state The state object to pass to <paramref name="continuation" /> when it's invoked.
token An opaque value that was provided to the <see cref="T:System.Threading.Tasks.ValueTask" /> constructor.
flags The flags describing the behavior of the continuation.